package com.jctrip.hotel.source.model.wehotel.req;

import java.math.BigDecimal;
import java.util.List;

/**
 * @Author: beihai
 * @Date: 2022-03-19 17:16
 * @Description:
 */
public class ProductData {
    /**
     * quota : 20
     * endOfDay : 1647619200000
     * rackRate : 558
     * spotRate : 530
     * advanceRate : 530
     * spotBreakfastCount : 0
     * advanceBreakfastCount : 0
     * cancelRule : {"supportCancel":2,"cancelPenaltyList":[{"start":"1970-01-01 08:00:00","end":"2022-03-19 18:00:00","cancelType":"0","type":null,"value":null},{"start":"2022-03-19 18:00:01","end":"2022-03-20 12:00:00","cancelType":"1","type":"0","value":"1"}],"newCancelPenaltyList":[{"cancelType":"0","type":null,"value":null,"minCount":0,"maxCount":3,"startHour":null,"endHour":6},{"cancelType":"1","type":"0","value":"1","minCount":0,"maxCount":3,"startHour":6,"endHour":null},{"cancelType":"0","type":null,"value":null,"minCount":3,"maxCount":null,"startHour":null,"endHour":30},{"cancelType":"1","type":"0","value":"1","minCount":3,"maxCount":null,"startHour":30,"endHour":null}]}
     * productCode : CORLJINSTAR
     * productName : 平台协议价
     * productType : 3
     * protocolType : null
     * freeCancelTime : 1647662400000
     * supportPay : ["0","1"]
     * hasEffiveTime : false
     * startTime : null
     * endTime : null
     * advanceFeeRate : null
     * spotFeeRate : null
     * guests : null
     * bookRule : {"maxAmount":null,"bminDay":null,"bmaxDay":null,"roomMaxAmount":1,"roomMinAmount":1,"checkMinDay":1,"checkMaxDay":1,"checkStartDateTime":null,"checkEndDateTime":null,"checkWeeks":null,"startDateTime":"2022-02-27 00:00","endDateTime":"2022-04-18 23:59","weeks":null,"minStayThrough":null,"maxStayThrough":null,"bookConstranit":[{"bookCheck":9,"bookCheckV":null}],"spotBackCash":null,"advanceBackCash":null}
     */

    /**
     * 可售房量
     */
    private Integer quota;

    /**
     * 营业日
     */
    private Long endOfDay;

    /**
     * 门市价
     */
    private BigDecimal rackRate;

    /**
     * 到付价
     */
    private BigDecimal spotRate;

    /**
     * 预付价
     */
    private BigDecimal advanceRate;

    /**
     * 到付早餐 null/0-无 1-单早 2-双早
     */
    private Integer spotBreakfastCount;

    /**
     * 预付早餐 null/0-无 1-单早 2-双早
     */
    private Integer advanceBreakfastCount;

    /**
     * 取消规则（锦江品牌需要用到）,取消规则优先看cancelRule，没有再看cancelTime
     * 新取消规则（维也纳品牌需要用到）,取消规则优先看cancelRule，没有再看cancelTime
     */
    private CancelRuleResponse cancelRule;

    /**
     * 商品编号
     */
    private String productCode;

    /**
     * 商品名称
     */
    private String productName;

    /**
     * 商品类型
     * 0 本店协议价
     * 1 批量分店品牌协议价
     * 2 组合品牌协议价
     * 3 平台协议价
     * 4 企业活动价
     */
    private Integer productType;

    /**
     * 协议类型
     * 0 分店协议
     * 1 品牌批量分店协议
     * 2 品牌组合协议
     * 3 自营销售分店协议
     * 4 自营销售品牌批量分店协议
     * 5 自营销售品牌组合协议
     */
    private Integer protocolType;

    /**
     * 免费取消时间(这个时间前预付的订单可免费取消时间)
     */
    private Long freeCancelTime;

    /**
     * 是否含有生效时间,false为永久有效
     */
    private Boolean hasEffiveTime;

    /**
     * 协议价格生效开始时间
     */
    private Long startTime;

    /**
     * 协议价格生效结束时间
     */
    private Long endTime;

    /**
     * 到付其他费用
     */
    private BigDecimal spotFeeRate;

    /**
     * 预付其他费用
     */
    private BigDecimal advanceFeeRate;

    /**
     * 丽笙单人价/双人价
     */
    private Integer guests;

    /**
     * 预定规则,目前只针对于活动价
     */
    private BookRuleBean bookRule;

    /**
     * 是否支持到付和预付0,1
     */
    private List<String> supportPay;

    public Integer getQuota() {
        return quota;
    }

    public void setQuota(Integer quota) {
        this.quota = quota;
    }

    public Long getEndOfDay() {
        return endOfDay;
    }

    public void setEndOfDay(Long endOfDay) {
        this.endOfDay = endOfDay;
    }

    public BigDecimal getRackRate() {
        return rackRate;
    }

    public void setRackRate(BigDecimal rackRate) {
        this.rackRate = rackRate;
    }

    public BigDecimal getSpotRate() {
        return spotRate;
    }

    public void setSpotRate(BigDecimal spotRate) {
        this.spotRate = spotRate;
    }

    public BigDecimal getAdvanceRate() {
        return advanceRate;
    }

    public void setAdvanceRate(BigDecimal advanceRate) {
        this.advanceRate = advanceRate;
    }

    public Integer getSpotBreakfastCount() {
        return spotBreakfastCount;
    }

    public void setSpotBreakfastCount(Integer spotBreakfastCount) {
        this.spotBreakfastCount = spotBreakfastCount;
    }

    public Integer getAdvanceBreakfastCount() {
        return advanceBreakfastCount;
    }

    public void setAdvanceBreakfastCount(Integer advanceBreakfastCount) {
        this.advanceBreakfastCount = advanceBreakfastCount;
    }

    public CancelRuleResponse getCancelRule() {
        return cancelRule;
    }

    public void setCancelRule(CancelRuleResponse cancelRule) {
        this.cancelRule = cancelRule;
    }

    public String getProductCode() {
        return productCode;
    }

    public void setProductCode(String productCode) {
        this.productCode = productCode;
    }

    public String getProductName() {
        return productName;
    }

    public void setProductName(String productName) {
        this.productName = productName;
    }

    public Integer getProductType() {
        return productType;
    }

    public void setProductType(Integer productType) {
        this.productType = productType;
    }

    public Integer getProtocolType() {
        return protocolType;
    }

    public void setProtocolType(Integer protocolType) {
        this.protocolType = protocolType;
    }

    public Long getFreeCancelTime() {
        return freeCancelTime;
    }

    public void setFreeCancelTime(Long freeCancelTime) {
        this.freeCancelTime = freeCancelTime;
    }

    public Boolean getHasEffiveTime() {
        return hasEffiveTime;
    }

    public void setHasEffiveTime(Boolean hasEffiveTime) {
        this.hasEffiveTime = hasEffiveTime;
    }

    public Long getStartTime() {
        return startTime;
    }

    public void setStartTime(Long startTime) {
        this.startTime = startTime;
    }

    public Long getEndTime() {
        return endTime;
    }

    public void setEndTime(Long endTime) {
        this.endTime = endTime;
    }

    public BigDecimal getSpotFeeRate() {
        return spotFeeRate;
    }

    public void setSpotFeeRate(BigDecimal spotFeeRate) {
        this.spotFeeRate = spotFeeRate;
    }

    public BigDecimal getAdvanceFeeRate() {
        return advanceFeeRate;
    }

    public void setAdvanceFeeRate(BigDecimal advanceFeeRate) {
        this.advanceFeeRate = advanceFeeRate;
    }

    public Integer getGuests() {
        return guests;
    }

    public void setGuests(Integer guests) {
        this.guests = guests;
    }

    public BookRuleBean getBookRule() {
        return bookRule;
    }

    public void setBookRule(BookRuleBean bookRule) {
        this.bookRule = bookRule;
    }

    public List<String> getSupportPay() {
        return supportPay;
    }

    public void setSupportPay(List<String> supportPay) {
        this.supportPay = supportPay;
    }

    public static class CancelRuleResponse {
        /**
         * supportCancel : 2
         * cancelPenaltyList : [{"start":"1970-01-01 08:00:00","end":"2022-03-19 18:00:00","cancelType":"0","type":null,"value":null},{"start":"2022-03-19 18:00:01","end":"2022-03-20 12:00:00","cancelType":"1","type":"0","value":"1"}]
         * newCancelPenaltyList : [{"cancelType":"0","type":null,"value":null,"minCount":0,"maxCount":3,"startHour":null,"endHour":6},{"cancelType":"1","type":"0","value":"1","minCount":0,"maxCount":3,"startHour":6,"endHour":null},{"cancelType":"0","type":null,"value":null,"minCount":3,"maxCount":null,"startHour":null,"endHour":30},{"cancelType":"1","type":"0","value":"1","minCount":3,"maxCount":null,"startHour":30,"endHour":null}]
         */

        /**
         * 取消方式{0: 不可取消, 1: 免费取消，2: 限时取消}
         */
        private Integer supportCancel;

        /**
         * 取消时间段规则。
         * 当cancelType=0时,表示在当前时间段免费取消（start-end）
         * 当cancelType=1时,表示在当前时间段有偿取消（start-end）,根据type罚金类型匹配惩罚值value
         */
        private List<CancelPenaltyResponse> cancelPenaltyList;

        /**
         * 新取消时间段规则。
         * 当cancelType=0时,表示在当前时间段免费取消（start-end）
         * 当cancelType=1时,表示在当前时间段有偿取消（start-end）,根据type罚金类型匹配惩罚值value
         */
        private List<NewCancelPenaltyResponse> newCancelPenaltyList;

        public Integer getSupportCancel() {
            return supportCancel;
        }

        public void setSupportCancel(Integer supportCancel) {
            this.supportCancel = supportCancel;
        }

        public List<CancelPenaltyResponse> getCancelPenaltyList() {
            return cancelPenaltyList;
        }

        public void setCancelPenaltyList(List<CancelPenaltyResponse> cancelPenaltyList) {
            this.cancelPenaltyList = cancelPenaltyList;
        }

        public List<NewCancelPenaltyResponse> getNewCancelPenaltyList() {
            return newCancelPenaltyList;
        }

        public void setNewCancelPenaltyList(List<NewCancelPenaltyResponse> newCancelPenaltyList) {
            this.newCancelPenaltyList = newCancelPenaltyList;
        }

        public static class CancelPenaltyResponse {
            /**
             * start : 1970-01-01 08:00:00
             * end : 2022-03-19 18:00:00
             * cancelType : 0
             * type : null
             * value : null
             */
            /**
             * 开始时间 yyyy-MM-dd HH:mm:ss
             */
            private String start;

            /**
             * 结束时间  yyyy-MM-dd HH:mm:ss
             */
            private String end;

            /**
             * 取消类型：0免费取消 1有偿取消
             */
            private String cancelType;

            /**
             * 罚金类型 0 房晚 1 百分数 2固定罚金
             */
            private String type;

            /**
             * 罚款值
             */
            private String value;

            public String getStart() {
                return start;
            }

            public void setStart(String start) {
                this.start = start;
            }

            public String getEnd() {
                return end;
            }

            public void setEnd(String end) {
                this.end = end;
            }

            public String getCancelType() {
                return cancelType;
            }

            public void setCancelType(String cancelType) {
                this.cancelType = cancelType;
            }

            public String getType() {
                return type;
            }

            public void setType(String type) {
                this.type = type;
            }

            public String getValue() {
                return value;
            }

            public void setValue(String value) {
                this.value = value;
            }
        }

        public static class NewCancelPenaltyResponse {
            /**
             * cancelType : 0
             * type : null
             * value : null
             * minCount : 0
             * maxCount : 3
             * startHour : null
             * endHour : 6
             */

            /**
             * 取消类型：0免费取消 1有偿取消
             */
            private String cancelType;

            /**
             * 罚金类型 0 房晚 1 百分数 2固定罚金
             */
            private String type;

            /**
             * 罚款值
             */
            private String value;

            /**
             * 最小房间数范围（部分有）
             */
            private Integer minCount;

            /**
             * 最大房间数范围（部分有）
             */
            private Integer maxCount;

            /**
             * 开始时间 小时 从当前入住时间24点开始减
             */
            private Integer startHour;

            /**
             * 结束时间 小时 从当前入住时间24点开始减
             */
            private Integer endHour;

            public String getCancelType() {
                return cancelType;
            }

            public void setCancelType(String cancelType) {
                this.cancelType = cancelType;
            }

            public String getType() {
                return type;
            }

            public void setType(String type) {
                this.type = type;
            }

            public String getValue() {
                return value;
            }

            public void setValue(String value) {
                this.value = value;
            }

            public Integer getMinCount() {
                return minCount;
            }

            public void setMinCount(Integer minCount) {
                this.minCount = minCount;
            }

            public Integer getMaxCount() {
                return maxCount;
            }

            public void setMaxCount(Integer maxCount) {
                this.maxCount = maxCount;
            }

            public Integer getStartHour() {
                return startHour;
            }

            public void setStartHour(Integer startHour) {
                this.startHour = startHour;
            }

            public Integer getEndHour() {
                return endHour;
            }

            public void setEndHour(Integer endHour) {
                this.endHour = endHour;
            }
        }
    }

    public static class BookRuleBean {
        /**
         * maxAmount : null
         * bminDay : null
         * bmaxDay : null
         * roomMaxAmount : 1
         * roomMinAmount : 1
         * checkMinDay : 1
         * checkMaxDay : 1
         * checkStartDateTime : null
         * checkEndDateTime : null
         * checkWeeks : null
         * startDateTime : 2022-02-27 00:00
         * endDateTime : 2022-04-18 23:59
         * weeks : null
         * minStayThrough : null
         * maxStayThrough : null
         * bookConstranit : [{"bookCheck":9,"bookCheckV":null}]
         * spotBackCash : null
         * advanceBackCash : null
         */

        /**
         * 最大入住人数
         */
        private Integer maxAmount;

        /**
         * 最少提前预定天数
         */
        private String bminDay;

        /**
         * 最大提前预定天数
         */
        private String bmaxDay;

        /**
         * 最大预订房间数
         */
        private Integer roomMaxAmount;

        /**
         * 最小预订房间数
         */
        private Integer roomMinAmount;

        /**
         * 最小入住天数(可等于)
         */
        private Integer checkMinDay;

        /**
         * 最大入住天数(可等于)
         */
        private Integer checkMaxDay;

        /**
         * 入住范围开始日期(yyyy-MM-dd)
         */
        private String checkStartDateTime;

        /**
         * 入住范围结束日期(yyyy-MM-dd)
         */
        private String checkEndDateTime;

        /**
         * "1,2,3,4,5,6,7", 可入住的星期几
         */
        private String checkWeeks;

        /**
         * 预定范围开始日期(yyyy-MM-dd HH:mm)
         */
        private String startDateTime;

        /**
         * 预定范围结束日期(yyyy-MM-dd HH:mm)
         */
        private String endDateTime;

        /**
         * "1,2,3,4,5,6,7", 可预定的星期几
         */
        private String weeks;

        /**
         * 表示若预订区间内，某一天这个属性有值，则整个连住天数，必须以这些天的最小minStayThrough，最大的maxStayThrough范围内
         */
        private Integer minStayThrough;

        /**
         * 表示若预订区间内，某一天这个属性有值，则整个连住天数，必须以这些天的最小minStayThrough，最大的maxStayThrough范围内。
         */
        private Integer maxStayThrough;

        /**
         * 到付返现(单位元，最多保留两位小数点)
         */
        private Double spotBackCash;

        /**
         * 预付返现(单位元，最多保留两位小数点)
         */
        private Double advanceBackCash;

        /**
         * 预定限制
         */
        private List<BookConstranitBean> bookConstranit;

        public Integer getMaxAmount() {
            return maxAmount;
        }

        public void setMaxAmount(Integer maxAmount) {
            this.maxAmount = maxAmount;
        }

        public String getBminDay() {
            return bminDay;
        }

        public void setBminDay(String bminDay) {
            this.bminDay = bminDay;
        }

        public String getBmaxDay() {
            return bmaxDay;
        }

        public void setBmaxDay(String bmaxDay) {
            this.bmaxDay = bmaxDay;
        }

        public Integer getRoomMaxAmount() {
            return roomMaxAmount;
        }

        public void setRoomMaxAmount(Integer roomMaxAmount) {
            this.roomMaxAmount = roomMaxAmount;
        }

        public Integer getRoomMinAmount() {
            return roomMinAmount;
        }

        public void setRoomMinAmount(Integer roomMinAmount) {
            this.roomMinAmount = roomMinAmount;
        }

        public Integer getCheckMinDay() {
            return checkMinDay;
        }

        public void setCheckMinDay(Integer checkMinDay) {
            this.checkMinDay = checkMinDay;
        }

        public Integer getCheckMaxDay() {
            return checkMaxDay;
        }

        public void setCheckMaxDay(Integer checkMaxDay) {
            this.checkMaxDay = checkMaxDay;
        }

        public String getCheckStartDateTime() {
            return checkStartDateTime;
        }

        public void setCheckStartDateTime(String checkStartDateTime) {
            this.checkStartDateTime = checkStartDateTime;
        }

        public String getCheckEndDateTime() {
            return checkEndDateTime;
        }

        public void setCheckEndDateTime(String checkEndDateTime) {
            this.checkEndDateTime = checkEndDateTime;
        }

        public String getCheckWeeks() {
            return checkWeeks;
        }

        public void setCheckWeeks(String checkWeeks) {
            this.checkWeeks = checkWeeks;
        }

        public String getStartDateTime() {
            return startDateTime;
        }

        public void setStartDateTime(String startDateTime) {
            this.startDateTime = startDateTime;
        }

        public String getEndDateTime() {
            return endDateTime;
        }

        public void setEndDateTime(String endDateTime) {
            this.endDateTime = endDateTime;
        }

        public String getWeeks() {
            return weeks;
        }

        public void setWeeks(String weeks) {
            this.weeks = weeks;
        }

        public Integer getMinStayThrough() {
            return minStayThrough;
        }

        public void setMinStayThrough(Integer minStayThrough) {
            this.minStayThrough = minStayThrough;
        }

        public Integer getMaxStayThrough() {
            return maxStayThrough;
        }

        public void setMaxStayThrough(Integer maxStayThrough) {
            this.maxStayThrough = maxStayThrough;
        }

        public Double getSpotBackCash() {
            return spotBackCash;
        }

        public void setSpotBackCash(Double spotBackCash) {
            this.spotBackCash = spotBackCash;
        }

        public Double getAdvanceBackCash() {
            return advanceBackCash;
        }

        public void setAdvanceBackCash(Double advanceBackCash) {
            this.advanceBackCash = advanceBackCash;
        }

        public List<BookConstranitBean> getBookConstranit() {
            return bookConstranit;
        }

        public void setBookConstranit(List<BookConstranitBean> bookConstranit) {
            this.bookConstranit = bookConstranit;
        }

        public static class BookConstranitBean {
            /**
             * bookCheck : 9
             * bookCheckV : null
             */

            /**
             * 预订限制类型 {0 提前预定 1 不可取消 2 不可预订 3 当天预订当天入住 4 本人预订本人入住 5 必须连住N晚以上 6 仅限预订当天 7 限制预订当天入住并允许连住N晚 8 是否仅开放指定天数 9 本人入住})
             */
            private Integer bookCheck;

            /**
             * 预订限制的值
             */
            private String bookCheckV;

            public Integer getBookCheck() {
                return bookCheck;
            }

            public void setBookCheck(Integer bookCheck) {
                this.bookCheck = bookCheck;
            }

            public String getBookCheckV() {
                return bookCheckV;
            }

            public void setBookCheckV(String bookCheckV) {
                this.bookCheckV = bookCheckV;
            }
        }
    }
}
